Skip to content

If a run has been claimed, move work order from "pending" to "running"#4637

Merged
midigofrank merged 5 commits intomainfrom
once-its-claimed-we-cant-get-it-back
Apr 20, 2026
Merged

If a run has been claimed, move work order from "pending" to "running"#4637
midigofrank merged 5 commits intomainfrom
once-its-claimed-we-cant-get-it-back

Conversation

@taylordowns2000
Copy link
Copy Markdown
Member

@taylordowns2000 taylordowns2000 commented Apr 17, 2026

This is likely to be super contentious, but the reality is that once it's claimed, we CANNOT STOP IT or get it back.

It can no longer be "cancelled". From the perspective of Lightning it's running, and we can't stop it.

Closes #4635

Validation steps

(Roina, can you show me how to find that edge case?)

AI Usage

Please disclose whether you've used AI anywhere in this PR (it's cool, we just
want to know!):

  • I have used Claude Code
  • I have used another model
  • I have not used AI

You can read more details in our
Responsible AI Policy

Pre-submission checklist

  • I have performed an AI review of my code (we recommend using /review
    with Claude Code)
  • I have implemented and tested all related authorization policies.
    (e.g., :owner, :admin, :editor, :viewer)
  • I have updated the changelog.
  • I have ticked a box in "AI usage" in this PR

This is likely to be super contentious, but the reality is that once
it's claimed, we CANNOT STOP IT or get it back.

It can no longer be "cancelled". From the perspective of Lightning it's
running, and we can't stop it.
@github-project-automation github-project-automation Bot moved this to New Issues in Core Apr 17, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 17, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 89.60%. Comparing base (f8a1f0b) to head (1d5ceae).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4637      +/-   ##
==========================================
- Coverage   89.63%   89.60%   -0.04%     
==========================================
  Files         444      444              
  Lines       21558    21558              
==========================================
- Hits        19324    19317       -7     
- Misses       2234     2241       +7     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@taylordowns2000 taylordowns2000 marked this pull request as ready for review April 17, 2026 16:04
taylordowns2000 and others added 2 commits April 17, 2026 18:23
…elog

Covers the end-to-end chain: a pending work order's Cancel button should
disappear in a live session once its run gets claimed, via Query.state_for
-> WorkOrders.update_state -> WorkOrderUpdated broadcast -> LiveView
re-render. Unit tests cover the SQL mapping; this covers the whole chain.

Also notes in the changelog that API consumers of /api/workorders and
workflow channel subscribers will observe the :pending -> :running shift.
@midigofrank midigofrank merged commit f0a1f01 into main Apr 20, 2026
7 of 8 checks passed
@midigofrank midigofrank deleted the once-its-claimed-we-cant-get-it-back branch April 20, 2026 14:39
@github-project-automation github-project-automation Bot moved this from New Issues to Done in Core Apr 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Cancelling Bulk Runs Button still active on claimed

3 participants